﻿Public Class Ruta
    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
        Dim oOpenFileDialog As OpenFileDialog
        oOpenFileDialog = New OpenFileDialog
        With oOpenFileDialog
            .DefaultExt = "accdb"
            .Filter = "Archivo base de Datos (*.accdb)|*.accdb"
            .InitialDirectory = "C:\"
            .ShowDialog()
        End With
        txtRuta.Text = oOpenFileDialog.FileName
    End Sub

    Private Sub Ruta_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        txtRuta.Text = direccion
    End Sub

    Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
        direccion = txtRuta.Text
        Me.Dispose()
    End Sub

    Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click
        Me.Dispose()
    End Sub
End Class